Fix #1180 Add the ability to build filters completely locally#1181
Open
Fix #1180 Add the ability to build filters completely locally#1181
Conversation
Strip volatile metadata lines (Checksum, Diff-Path, TimeUpdated, Version) from compiled filter files after build. Reduces noise when comparing outputs between compiler versions.
maximtop
requested changes
Apr 6, 2026
- one-liner => helper function - .txt extension to the constant in strip_generated_meta.js
maximtop
requested changes
Apr 13, 2026
maximtop
requested changes
Apr 13, 2026
slvvko
reviewed
Apr 22, 2026
slvvko
requested changes
Apr 22, 2026
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
maximtop
approved these changes
Apr 29, 2026
Comment on lines
+53
to
+57
| if (useCache && generateCache) { | ||
| // eslint-disable-next-line no-console | ||
| console.error('Error: --use-cache and --generate-cache are mutually exclusive.'); | ||
| process.exit(1); | ||
| } |
Contributor
There was a problem hiding this comment.
Non-blocking: this block is dead code now — validateFlags(flags) on line 32 already catches useCache && generateCache and exits at line 39. Safe to remove.
Comment on lines
+28
to
+39
| '--no-patches-prepare', | ||
| '--strip-generated-meta', | ||
| ]); | ||
|
|
||
| expect(flags.useCache).toBe(true); | ||
| expect(flags.noPatchesPrepare).toBe(true); | ||
| expect(flags.stripGeneratedMeta).toBe(true); | ||
| }); | ||
|
|
||
| it('ignores unknown arguments', () => { | ||
| const flags = parseFlags(['--mode=unknown', '--foo']); | ||
| expect(flags.useCache).toBe(false); |
Contributor
There was a problem hiding this comment.
Non-blocking: --generate-cache is missing from this test. The other three boolean flags are covered but generateCache is not asserted.
Suggested change
| '--no-patches-prepare', | |
| '--strip-generated-meta', | |
| ]); | |
| expect(flags.useCache).toBe(true); | |
| expect(flags.noPatchesPrepare).toBe(true); | |
| expect(flags.stripGeneratedMeta).toBe(true); | |
| }); | |
| it('ignores unknown arguments', () => { | |
| const flags = parseFlags(['--mode=unknown', '--foo']); | |
| expect(flags.useCache).toBe(false); | |
| it('parses all boolean flags', () => { | |
| const flags = parseFlags([ | |
| '--use-cache', | |
| '--generate-cache', | |
| '--no-patches-prepare', | |
| '--strip-generated-meta', | |
| ]); | |
| expect(flags.useCache).toBe(true); | |
| expect(flags.generateCache).toBe(true); | |
| expect(flags.noPatchesPrepare).toBe(true); | |
| expect(flags.stripGeneratedMeta).toBe(true); | |
| }); |
slvvko
approved these changes
Apr 29, 2026
zloyden
approved these changes
Apr 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

#1180